// part1:C15:15.7:Limited_quote.h
// class Limited_quote.
#ifndef LIMITED_H__
#define LIMITED_H__
#include <iostream>
#include "../15.3/Quote.h 
class Limited_quote : public Quote
{
public:
    double net_price(size_t cnt) const override
    {
        if (cnt <= min_qty)
        {
            return cnt * (1 - discount) * price;
        }
        else
        {
            return min_qty * (1 - discount) * price +
              (cnt - min_qty) * price;
        }
    }
private:
    size_t min_qty;
    double discount;
};
#endif
